package com.service;

import com.dao.ActivityDao;
import com.domain.Activity;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.ArrayList;

@Service
public class ActivityServiceImp implements ActivityService {
    @Autowired
    private ActivityDao activityDao;

    @Override
    public ArrayList<Activity> findActivityAll() {
        return activityDao.findActivityAll();
    }

    @Override
    public Integer insertActivity(Activity activity) {
        return activityDao.insertActivity(activity);
    }

    @Override
    public Integer deleteById(Integer id) {
        return activityDao.deleteById(id);
    }

    @Override
    public Integer updateById(Activity activity) {
        return activityDao.updateById(activity);
    }

    @Override
    public Activity selectOne(Integer id) {
        return activityDao.selectOne(id);
    }
}
